0

I am looking for data, but I don't know the name of the table, neither of the column.

As you might know, it's possible to create the backup of an SQL-Server database. Launching a grep on that backup indeed reveals that the mentioned data exist, but it does not mention the name of the table and/or column.

Is there a way to find data inside an SQL-Server database, either by some SQL, either by creating a human readable textfile from a DB?

Thanks in advance

2
  • In the meantime, I've found the possibility to "Generate Script", using Microsoft SQL Server Management Studio, but this only seems to save the format of the tables and columns, not the data. Any ideas?
    – Dominique
    Sep 12, 2023 at 9:56
  • 1
    I am not sure this is possible with some straight away technique but you should refer to This Link. This has query to search for string in each table. It would be a arduous task but this is what I can get.
    – Shanky
    Sep 12, 2023 at 10:01

1 Answer 1

1

I have found a way how to do this, using "Generate Script". The thing is that, while doing that, the choice "schema and data" needs to be chosen for the "types of data to script" question, as can be seen in this screenshot:

enter image description here

1
  • 1
    This is typically the least cumbersome way I've used. Depending on the size of the database, you may want to have it save each Table to a separate file. Then you can use a search tool like AstroGrep or grep to tell you which file and like number the piece of data is on.
    – J.D.
    Sep 12, 2023 at 12:18

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.