Find Data Location
Sep 26, 2003
Hi,
I wanted to find the location in database objects(table/stored proc/view/function) for particular text.
For example a text 'BU1032' is located in tiles and titleathor table at PUBS databse.
I wanted get the result like
text_name filed_name table_name
--------- --------- ---------
BU1032 title_id titles
BU1032 title_id titleauthor
if we are using in stored proc/view for comparison that should be display
like
text_name storedproc_name
-------- ---------------
BU1032
Anybody has script for this kind of search?.
Thanks,
Ravi
View 6 Replies
ADVERTISEMENT
Jun 11, 2015
Script to find the details of creation date and modified date of all files located in a path?
I wanna write few custom messages before I delete some files from a path.
View 9 Replies
View Related
Jun 16, 2008
Hi Guys,
I'm actually a beginner in SQL Server and I got use to a database called "Cache" where the Data itself is stored separately from the tables (Table definition), and I'm wondering if its the same in SQL Server where the Data is stored in a deferent location then the Table definition, and if so, where it could be stored?
Thanks.
View 3 Replies
View Related
Oct 14, 2004
Hi all,
I need to compare and match two fields, the data can be in following manner:
first_name/tableA first_name/tableB
Diana R Diana
Diana Diana Rosa
Diana R Diana R
Diana Patrick
My result should find only Diana and Patrick as nonmatch and all other as match.
How should I write the query?
Thanks in advance!!
View 1 Replies
View Related
Jun 16, 2008
Hello. I have been challanged to build an application that keeps track of inventory and dates of every item that needs inspection on regular intervals. The original application was a .NET windows application and i have been tasked to "port" and improve it to a .NET C# web application.
The original database was in access and i have imported everyting to SQL and all the data is in a single table. So far the table is relatively small so i decided to keep the current database design.
What i need to do is to select all the items that are comming up for inspection in the comming months and present them. Each item has a uniqe article number (artnr) with the item name, category and location of the item. The location is the part i would like each items to be presented by. Basicly i would like to retrive artnr, name, type and present x number of gridviews or a sorted presentation where each item is shown inside each gw/whatever by location.
I also considered moving all locations to it's own table and connect it with a PK/FK to the prinmary article table but i dont know if this will help me or not. Basicly i have no idea how i would present the items by location where each gridview/somethign else is it's own location.
I could really use som help with how i can retrive and present the data so it is showed in the above manner.
View 1 Replies
View Related
Sep 26, 2000
Hi everybody,
On the time of installation SQL Server asking me where I wont to locate the DATA files and the PROGRAM files. It’s giving to me choice to put database AND log files on one disk and program files on separate. But what about to separate LOG and DATA files. I have RAID1 especially created on F: drive for LOG files and RAID 5 on E: for DATABASE files. When I have to separate that if not on the time of installation? How I can do that?
Thanks,
Miriam
View 3 Replies
View Related
May 17, 2007
Hi, I am working on a new installation which I did not set up and realized was using the wrong partition of the server to store the data and log files, I have already created several databases, I want to use another partition for these databases without having to drop them and create them all over again.
In BOLine i saw this command but want to make sure its safe, hope somebody can comment on this or if I am missing something.thank you
proposed command:
"MODIFY FILE ( NAME = logical_file_name, FILENAME = 'new_path/os_file_name ' )"
View 7 Replies
View Related
Jan 28, 2008
Hi All,
Can plz any one help me, acutally as i know sys.files table gives you the acutally physical location of the database fiels with name as well like this
C:sqldatax.mdf
but what i m looking is, is there any qury or script that will give me only the path of the data,log, index files like this
C:sqldata
Thanks and looking forward.
-MALIK
View 5 Replies
View Related
Mar 15, 2007
Hey all, WE have a document management system where by Adminstrators can upload documents, once the document is uploaded the binary data is stored on in a folder on the web server. We used to stored the documents in the actaul db table, but we found that there were to many documents and it was using alot of space on db server. So my boss has decided we are now going to upload the binary data onto the web server. Currently we are donig this with new documents which have been added or documents which are gettinguploaded when reloading, but there are many documents in the db table which have not been updated and are still embedded in the db table. So i need to figure out how to go about copying the data storewd in the db table and storing it in web servers folder location. I've tried various things for a enitre day but im going round in circiles. MemoryStream mStream = new MemoryStream((Byte[])dtrResults["file"]); BinaryReader bReader = new BinaryReader(mStream); int intFileSize = (int)mStream.Length; Byte[] byteFile = (Byte[])dtrResults["file"]; i can get to this state but then how do i create a folder on the BinaryREader to then store the binary data of the file to the location. BinaryReader bReader2 = new BinaryReader(File.Open(strDocFolder + strSavedFileName, FileMode.Create)); int count2 = bReader2.Read(byteFile, 0, intFileSize); bReader2.Close();i've also tried this but when the file gets created in the folder there is no content. i do know that the file does contain content as ive tried this and downlaoding the file from that page acctually works string strContentTpe = WValue.WStr(dtrResults["contenttype"]); int intFileSize = VValue.VInt(dtrResults["filesize"]); / Byte[] byteFile = ((Byte[])dtrResults["file"]); //Downloads the data correctly Response.ClearContent(); Response.ClearHeaders(); Response.AddHeader("Content-Disposition", "attachment; filename="" + WValue.WStr(dtrResults["docfilename"]) + """); Response.AddHeader("Content-Length", WValue.WStr(intFileSize)); Response.ContentType = strContentTpe; Response.BinaryWrite(byteFile); I hope ive made some snese andthat someone can hlep me. Have a nice dayZal
View 2 Replies
View Related
Feb 27, 2007
During installation of SQL Server 2000 I set the default location for data files as D:MySQLServer which resulted in the location D:MySQLServerMSSQL.
I then installed SQL Server 2005. I do not remember being given the option of specifying location for the Data Files. Then I read that the location for named instances is deteremined by the first installation of SQL Server. The location for the data files for SQL Server 2005 turned out to be MSSQL.1 but under C:Program Files.....
I want the default location for SQL Server 2005 to be under D:MySQLServer, something like D:MySQLServerMSSQL.1. How do I do I change the default location for the Data Files.
Jay
View 9 Replies
View Related
Nov 9, 2015
I added a secondary data file to TEMPdb yesterday and gave it a wrong location by mistake. If I try to change the location, then I am getting an error now. I think that is because TEMPdb is in use and that is why I cant change it's secondary file's location. Do I need to take TempDB offline and then change the secondary file's location??
View 3 Replies
View Related
Sep 29, 2006
Hey everyone I've got this question that has me stuck for the last few days but its an important part of my website.....What I am trying to do is basicly have a user be able to upload a file, have that uploaded file plus some other info automaticly display on other parts of my site, and have a different user eventually be able to download that file....I have thought about allowing the file upload as a BLOB but still cannot find a proper way to execute this using VB, plus I have heard that this way of doing it is not reccommeneded cause databases were not designed to store large files like this, lots of articles recommened having the file upload to a Folder on your server then get the binary data for the file that can be placed in a database to refrence that particular file.....Well this also proves to be a lot harder then said here is what I got so far (written in C#) protected void UploadBtn_Click(object sender, EventArgs e)
{
if (FileUpLoad1.HasFile)
{
FileUpLoad1.SaveAs(@"C:Documents and SettingsAdamMy DocumentsVisual Studio 2005ProjectsWebsiteFiles" + FileUpLoad1.FileName);
Label1.Text = "File Uploaded: " + FileUpLoad1.FileName;
}
else
{
Label1.Text = "No File Uploaded.";
}
}
and here is the asp part of the code that goes with it<asp:FileUpLoad id="FileUpLoad1" runat="server" />
<asp:Button id="UploadBtn" Text="Upload File" OnClick="UploadBtn_Click" runat="server" Width="105px" />
<asp:Label ID="Label1" runat="server" Text=""></asp:Label>
Now from what I know is I need to get the binary of the file which I have read you can do with the Page.Request.Files statement but again not sure how I would impliment this. Does anyone have any suggestions on which way I should take when dealing with this should I try and just use the BLOB method or use the binary refrence method? and if so how would I impliment this, heck even some good tutorials on the subject would be great... Thanks.....Adam
View 8 Replies
View Related
Aug 29, 2015
there are several remote locations where sql is running, my company has asked me to find a way to collect all the data from the remote locations to a central location automatically,for example day to day data should be synced at night time from 2am to 7 am and it should be compressed automatically before data transfers to the central location. NOTE there is no domain only standalone workstations
View 3 Replies
View Related
Apr 23, 2015
Where is a package visible when running the Data Import/Export wizard, choosing to save a package, and choosing "SQL Server" as the location? When I make an SSIS connection in Management Studio I do not see the package under the "MSDB" node.
View 4 Replies
View Related
Oct 4, 2007
Hi all,
It looks like these options are only available in the SQL Server Management Studio? I installed SQL Server Management Express Studio and I can't even find the DTSWizard.exe on my machine.
Can you please help how I can import data from excel or where can I download the SQL Server Management Studio?
Your prompt response is greatly appreciated.
Thanks!!
Tram
View 8 Replies
View Related
Jun 18, 2007
Hi ALL
Just wondering is there an easy way to search every table and every column for a specific piece of data in sql 2000?
Any ideas would be appreciated
Cheers
Phil
View 2 Replies
View Related
May 30, 2008
What I would like to do, is loop through a table, extract two fields from each record, and pass the values of those fields to a stored proc. I found some help on using cursors to do this, but can I use two cursors at the same time? Below is what I would like to do:
DECLARE @cursorPhone CURSOR, @cursorName cursor, @phone VARCHAR(30), @UserName varchar(50)
SET @cursorPhone = CURSOR
FOR
SELECT userPhone FROM dbo.RPM_Data
OPEN @cursorPhone
FETCH NEXT FROM @cursorPhone INTO @Phone
SET @cursorName = CURSOR
FOR
SELECT userName FROM dbo.RPM_Data
OPEN @cursorName
FETCH NEXT FROM @cursorName INTO @UserName
WHILE @@FETCH_STATUS = 0
BEGIN
EXEC sp_Subscription_Individual @phone, @UserName
FETCH NEXT FROM @cursorPhone INTO @phone
FETCH NEXT FROM @cursorName INTO @Username
END
DEALLOCATE @cursorPhone
DEALLOCATE @cursorName
View 2 Replies
View Related
Apr 17, 2015
is it possible to find out all the data about the table so I need Table columns, type etc.
View 1 Replies
View Related
Jun 7, 2007
how to find data mining 's example from sql2005
how to apply data mining in project
View 3 Replies
View Related
Oct 15, 2007
Hi,
I use Visual Studio 2005 Pro.
I installed Microsoft SQL Server Compact Edition Developer Software Development Kit .
When i try to make a connection , i can't change the datasource to the compact version.(Not vissible)
What could be the problem.
Sorry for my bad english,
Thx
JoskeXP
View 3 Replies
View Related
Nov 15, 2007
I got a table in sql server....
i don't know the field name where data is present.
i just want to search and find, where data is present in any field of that table.
How can i do?. I forgot that SQL.
Please help me.
View 4 Replies
View Related
May 9, 2008
TableName: EmployeeCloumns: EmployeeID EmployeeName If I do "Select * From Employee", is there a way to do something like this...
Loop through each result IterateThroughControls.ID &= dbTable & dbColumnName & "<br />"EndSo that the end result would assign ID values...EmployeeEmployeeIDEmployeeEmployeeName
View 5 Replies
View Related
May 18, 2006
How do I find data having max length in the Database ?
View 1 Replies
View Related
Jan 18, 2000
Hello,
I have a quick question. Can you please tell me how to find/search a string/value in all of my tables in a database.
For example I need to find a value/data "GH45678", where-ever it appears in a database.
I would really appreciate your prompt response. I would also like to thank you very much in advance for your time/help.
Note: I need to find specific data in all of my tables, I am looking for something like text search in my database. I am using SQL Server 6.5. Thanks
View 1 Replies
View Related
May 7, 2002
I need to find out when the data file and transaction log file is full. Is there any stored procedure that will let how much space left. We don't want to set Autogrow for the files.
Thanks,
Rau
View 2 Replies
View Related
Jun 14, 2007
I need to find a table and column name from some given data. I know what data i want to edit, I just need to know where it is located and the database is too big to manually go through. It is Microsoft sql server 2000. Any help is appreciated.
View 9 Replies
View Related
Oct 7, 2015
I have partitions that I have filled with data. I am not trying to figure out exactly how much data the partitions contain, and therefore I will be able to see if any of them are close to hitting their autogrow conditions. If I were looking at a single unpartitioned table, then I could maybe look at the table properties to determine data and index sizes, and compare that to the size of the mdf file size, but for partitions, then I am not sure how I would query this information out. Any pointers on how this information could be queried out of the system?
View 3 Replies
View Related
Nov 22, 2013
I am trying to write a piece of SQL which gives me a list of enquiries within 10 metre distance of a enquiry.
The idea is to identify possible duplicates.
Table: enquiry
Primary key: enquiry_number
Co-ordinates data fields: enquiry.enquiry_easting and enquiry.enquiry_northing.
I will need to self-search on the same table to find possible enquiries within 10m distance.
View 1 Replies
View Related
Jul 23, 2005
Here is an issue that has me stumped for the past few days. I have atable called MerchTran. Among various columns, the relevant columns forthis issue are:FileDate datetime, SourceTable varchar(25)SQL statement:SELECT DISTINCTFileDate, SourceTableFROMMerchTranORDER BYFileDate, SourceTableData looks like this:FileDate DataSource-----------------------------------2005-02-13 00:00:00.000S12005-02-13 00:00:00.000S22005-02-13 00:00:00.000S32005-02-14 00:00:00.000S12005-02-14 00:00:00.000S22005-02-14 00:00:00.000S32005-02-15 00:00:00.000S22005-02-15 00:00:00.000S32005-02-16 00:00:00.000S12005-02-16 00:00:00.000S22005-02-16 00:00:00.000S32005-02-17 00:00:00.000S12005-02-17 00:00:00.000S22005-02-18 00:00:00.000S12005-02-18 00:00:00.000S22005-02-18 00:00:00.000S32005-02-19 00:00:00.000S12005-02-19 00:00:00.000S3We run a daily process that inserts data in to this table everyday forall 3 sources S1, S2, S3Notice how some data is missing indicating the import process for thatparticular source failed.Example: Missing record2005-02-15 00:00:00.000S12005-02-17 00:00:00.000S32005-02-19 00:00:00.000S2Can someone please help me with a SQL Statement that will return me the3 missing records as above.Thanks in advance for all your help!DBA in distress!Vishal
View 4 Replies
View Related
Jul 23, 2005
I would like some advice on a data and query problem I face. I have adata table with a "raw key" value which is not guaranteed to be validat its source. Normally, this value will be 9 numeric digits and map toa "names" table where the entity is given assigned an "official name".My problem is that I'd like to be able to identify data values that are"close" to being "correct". For example, in the case of anine digit number such as 077467881, I'd like to be able to identifyrows with values close to this raw string. That is, ifthere were a row with a value for this column that was "off" by say, atransposed single digit (such as 077647881 in this example)I would like to find a query to locate the "close candidates" in aresult set. If I can find rows having a raw keyvalue that is close to a "good key" then I can allow my user to useother criteria to possibly assign the "close key" asan alternate or alias of the official key. Here is part of my schema:CREATE TABLE MYData (StateCD char (2) NOT NULL ,CountyCD char (3) NOT NULL ,MYID int NULL ,RawNumString varchar(9) NULL ,SaleMnYear datetime NOT NULL ,NumberWidgets int NOT NULL ,)CREATE TABLE MYNames (MYID int IDENTITY (1, 1) NOT NULL ,OfficialName varchar (70) NOT NULL ,CONSTRAINT PK_MYNames PRIMARY KEY CLUSTERED(MYID))CREATE TABLE MYAltID (RawNumString varchar (9) NOT NULL ,MYID int NOT NULL ,CONSTRAINT PK_MYALTID PRIMARY KEY CLUSTERED(RawNumString) ,CONSTRAINT FK_HasName FOREIGN KEY(MYID) REFERENCES MYNames (MYID))So, how to generalize something like:SELECT * FROM MYData WHERE RawNumString = '077467881'OR RawNumString = '077647881'
View 6 Replies
View Related
May 14, 2008
I need a query that checks each row in a column (hardness) to see if the last character is a "space". The column holds numbers (73.45) but is a varchar 50 type. It will always be the 5th character but it would be nice to not make this assumption. Please help!!
Thanks.
View 5 Replies
View Related
Jul 6, 2004
SQL Server 2000 Enterprise
While testing an update script I found that a number of data rows are inaccessible using my query, though the data does exist in the table. I can browse records to find the data or query the record by some column names, but not by others.
For example:
SELECT name FROM tblPersonalInformation WHERE [ID Number] = 2358899;
would not find the data sought. However, if I put in:
SELECT address FROM tblPersonalInformation WHERE name = ‘Doe, John’;
the query yields the desired data. Many of the records queried display the specified data with no problem. I have found this problem to exist on a number of data rows, but can’t figure out a reason. The front-end application displays the data without any apparent problems.
Ideas please.
View 1 Replies
View Related
Jul 6, 2004
SQL Server 2000 Enterprise
While testing an update script I found that a number of data rows are inaccessible using my query, though the data does exist in the table. I can browse records to find the data or query the record by some column names, but not by others.
For example:
SELECT name FROM tblPersonalInformation WHERE [ID Number] = 2358899;
would not find the data sought. However, if I put in:
SELECT address FROM tblPersonalInformation WHERE name = ‘Doe, John’;
the query yields the desired data. Many of the records queried display the specified data with no problem. I have found this problem to exist on a number of data rows, but can’t figure out a reason. The front-end application displays the data without any apparent problems.
Ideas please.
View 5 Replies
View Related