I have deleted one of my content from my Drupal site of WEB form content type.
Now I need to retrieve its report.
Please guide me on how to retrieve the report or database of a deleted web form.
Thanks in advance,
Anamika.
EDIT: Assumption that this is about Drupal 8 since this is not mentioned in the OP's question.
I am afraid you can't retrieve data from your webform once it's deleted. When you deleted the webform you expliytidly confirmed that you're okay with the deletion and all its related data.
If you happen to have a database backup, there is some hope to retrieve the data. Webform data is spread over multiple tables, here are the most important ones:
webform: List of all your webforms and their ID
webform_submission: List of all submissions (1 line per submission)
webform_submission_data: List of all your fields & values for a submission
So if you have a database backup, you can probably retrieve all the sid (submission id's) from webform_submission for the deleted webform and then retrieve all the data then in the webform_submission_data table.
If you don't have any kind of database back-up, I am afraid your data is lost forever.
Related
The website I'm working on uses gravity forms and gravity form PDFs to generate PDFs from form data. There was a typo in one of the form field options. When I fixed the typo, every entry lost its data for that form field. Thankfully, this happened in a sandbox environment and the staging environment still has all of the information for that form field.
I have gone through every single table on the database and could not find where the information for these entries are stored. I also checked through the local file structure.
Does anyone know where the form field data is stored with Gravity Forms?'
EDIT:
Sorry, it was just mySQLworkbench being stupid. I had my rows set to 1000 and it was displaying 1044. That made me assume there were only 1044 rows... There were thousands of rows I didn't check. I changed my query and that fixed it
Any uploaded files will be stored in the wp-content/uploads/gravity_forms/$FORM_ID-randomstring folder. Any text entered in your form fields will be store in your WordPress database in dedicated Gravity Forms tables. A reference to any uploaded file will be stored in the database as well.
for more information please click the link https://docs.gravityforms.com/database-storage-structure-reference/ or check out other peoples contribution here >>https://legacy.forums.gravityhelp.com/topic/where-does-the-gravity-form-information-go-after-it-is-created
I'm building a website that will be used by employees to log work that they've completed. The site contains a page to submit the information, a page to view the information and a page with the employees personal info like name, email, phone, etc. I'm using ASP.NET Membership for authentication. All code will be VB. My questions:
1) ASP.NET Membership only stores the username and email of members. I want to store additional information like first and last name, phone number, etc. Can I just update the tables in the membership database to include this information? Or should I store this information in a separate database? My goal is to populate text boxes on one of the pages with data specific to the user that is currently logged in.
2) The work completed will be stored in another database since it seems logical to keep it separate from membership data. What is the most efficient way to pull and display records from this separate "work" database that are specific to the user who has logged in and been authenticated against the member database?
3) I'm having trouble with the design of tables for the "work" database. Each record stored in the database will represent a days worth of work. However, a number of activities will occur during that day. Each activity will have a type of activity, location and amount of time worked. An employee can complete 1 activity or 100 activities. I assume I'm going to need a table just for the activities and then relate it to the work table. Does this sound correct?
For your first Point i will suggest you to create your own table of User and relate this table with membership user table with guid viz. keep on userid file in your table and relate it with membership table.
Second point will automatically get solved once you will create your own user table, all you need is to relate work and user table(created by you) to fetch the records from work
And at last if you are creating new table for activities how come you will relate it to your work table, again you will have multiple occurrence for record, instead i would suggest do not create another table for activities keep it in work table itself as if you are creating a new table, you will have to provide relationship with work which will result in redundancy.
Hope this helps.
I’m in the middle of writing a blog site in asp.net (VB) and am trying to add thumbs up / down voting buttons to each article in an asp.net repeater control. The site is driven from an SQL database and im looking for the best way to achieve this? Im hoping to end result will have a similar look and feel to reddit, stackoverflow & youtube voting.
I’m using SQL membership for security and will request that the user logs in before they can vote. I know I will need to store the following values (article ID, user id, vote value) so the total can be updated and stop any duplicate voting.
I’ve created 3 tables (Articles, Votes, Users). The votes table will record each vote storing the (article id, userid, vote value). I have also added a ‘vote total’ field to the articles table which will be updated via a stored procedure each time a vote is made. This should help performance when showing the articles.
What I cant work out is the best way to implement the buttons against each article?
I would be extremely grateful for any advise, Thanks
The voting control is within the repeater, and the repeater can store a unique ID to the article in each row, by using the DataKeys collection. If everything is being done server-side, you could retrieve the ID of the row using this data keys collection, and pass that along with the request to do the vote.
If you are talking client-side, then you'd have to store the article ID on the client somewhere (hidden field or other), and then extract it from the hidden when you go to push the request to the server.
I'm working on a web application, on one page I am inserting records in the database and I want to display the data in a GridView but on a diffrent page. How can I do this?
I know how to display records in a GridView, but I want to know if there are two web pages,
on one page provides the facility to insert the records and U want to display the records in the GridView bit on the second page.
While it is possible to retain the data being inserted without retrieving it from the database, I think it is better to save the data on the first page and retrieve it from the database on the second page.
You can do this by writing inline SQL or a stored procedure. One simple approach would be to pass the resultset into a DataTable and bind a GridView to that.
That does involve more work -- more code and more trips to the database. However, I think it is very useful when performing INSERTs that the web page is updated to display what actually got into the database. Sometimes, this is different from what the user thinks they entered, and they can see the problem immediately.
One question would be how to identify the data that has just been inserted. I can think of several ways to do that. One is to query for all records entered today by the person logged in (which is recorded in the CreatedBy and CreatedDate columns of the database tables). Sort the resultset in descending order of CreatedDate, so that the most recent entries appear at the top of the GridView. Another would be by assigning a batch number to the data entry and retrieving only the data in that batch.
If you really want to hang on to the data entry, you could put it into Session on the first page, and then retrieve it from Session for display on the second page.
Following along the lines of what DOK said, it's also a lot easier to validate data entered by your users in your business logic before you submit it to the database.
Secondly, users can change their minds about data on a webpage frequently. The data on the web could be in an partially-finished state or could have typos or errors in it. If someone else saw this data and believed that it needed to be completed, then you could end up with duplicated entries in the database that would then require reconciliation.
Honestly, your best bet is to use the Session object to hold temporary user data. The MSDN entry for the GridView RowEditing event contains some great source code for this approach. Whenever I have to use GridViews to handle data from the database, I mimic this.
In addition to handling problems with temporary data storage, you can compare the Session object to your database results to determine whether or not new rows have been inserted. This is somewhat costly as it involves overloading the Equals method (and GetHashCode as well, if you follow what Microsoft recommends) and using Equals to iterate over the two collections, comparing the properties of both objects, and determining which records are new based on records that don't exist in your Session object, but do exist in your database object.
It's also worth noting that this approach assumes that you don't delete data from your database, but set the status of a record in your database to "Deleted" -- if that's a boolean field or an sequence of codes you use to describe the state of rows in a table.
I just set up user profiles using asp.net 3.5 using wvd.
For each user I would like to store data that they will be updating every day.
For example, every time they go for a run they will update time and distance. I intend to allow them to also look up their history of distance and time from any past date.
My question is, what does the database schema usually look like for such a set up? Currently asp.net set up a db for me when I made user profiles. Do I just add an extra table for every user? Should there be one big table with all users data? How do I relate a user I'd to their specific data? Etc....
I have never done this before so any ideas on how this is usually done would be very helpful. Thank you.
One easy way is to just add a (one) table to aspnetdb database, this table will be used to track your running session data for all the user profiles. Name it RunnerSessions or something similar, add the following columns to the table:
UserID (use this field to store the profile id from ASP.NET)
SessionDate (use this field to store the run session date)
SessionDistance (use this field to record the distance from that particular run session)
It is a good idea to make UserID + SessionDate fields as your primary key for the RunnerSessions table or create another field called SessionID and set it as autonumber.
To relate each profile to a particular record in the RunnerSessions table, you can store the HttpContext.Current.User.Identity.Name in the UserID field mentioned above.
You are asking for a relational database design. As relational database design is an art in itself and heavily depends on a lot of case specific conditions I will not be able to provide you with a ready-to-go schema.
As I never read any online tutorial about this I will also not post a link here. But you should be able to get started by searching for a relational database design (tutorial) in your favourite search engine.
Maybe someone knows about a good tutorial and can post a link?