Work Around Of Using A Reserved Word In OLE DB Destination?
Jul 25, 2007
Hi!
We are encountering an issue of using OLE DB destination with the field name of the table is a reserved word in the database.
The database is DB2 V8 (mainframe). "partition" is one of the reserved word in V8 (It is not in the previous version and the whole thing worked fine).
It errors out when it reaches to the OLE DB destination task to do the insert. It complaints about using the reserved word, "partition". We could use an "OLE DB command" (instead of a to do an OLE DB Destination) with the insert SQL statement explicitly by putting double quote around the field name, partition in the insert statement. It works this way. But We wondered if there is any work around of using a reserved word in OLE DB destination in that case?
I migrated a SQL7 database to a SQL2000 server by restoring from a backup file. Everything worked fine until we restarted the SQL Service a few days later and suddenly a table named Function caused me much grief
It seems Function is a reserved word in 2000 - but not in SQL 7.
I am guessing the restore fooled the system into thinking it was a SQL7 database until the restart? Anyone have any ideas why else it would have worked just fine for 5 days, then die on a restart of SQL service (not even a reboot!)
I haven't found anything that shows that "sample" is a reserved word in SQL 2000. However when I enter it in Query Analyzer, the color changes to blue, as it is a transact-sql word. However, I'm still able to create a table called sample or name the column.
Does anybody know why query analyzer recognizes it as a transact-sql/reserverd word??
Is the word "Name" a reserved word in SQL? look at line 10 of my stored procedure. When I use the word "Name"it is highlited in blue by SQL Server? Note I only list part of the stored proc 1 CREATE PROCEDURE [dbo].[GetXMLPeopleNames] 23 (4 @Status nvarchar(3)5)6 AS7 SELECT8 PersonId,9 PersonDescription,10 Name,11 UpdateDate,12 UpdateAppUser13 FROM14 Customer WHERE Customer.PersonDescription=@Status15 ORDER BY
I have a doubt regarding SSIS data destinations. I have a word document which is stored in the sql database table as varbinary(max). I want to fetch that doument and load it into word document through ssis.Is it possible?If so,how to do it?
One more question regarding data destination..I have created an interface to execute the ssis package from asp.net application.The package will be run by sql server agent.The question is is there any way that the package output will be shown on the local machine rather than host machine(which has interface and package).
I have a package that works fine on XP. I copy it (and the databases used within it) to my new Vista Business Edition box (with SQL 05 SP2 with Hotfix.) Both the source and destination databases are on the 05 SP2 with Hotfix installation on this Windows Vista box (this is a completely local transformation.) The account I am logged in with is an Administrator on the box (and I have done the whole Vista provisioning deal.) Furthermore BUILTINAdmins is not disabled. Furthermore I went so far as giving this account every server role.
Short of it is when I use SQL Destination it fails - regardless of the options used. When I use an Ole Db Destination it works.
So, to prove that I am not crazy I recreated this package from scratch, and used a SQL Server Destination. The account I am using has essentially every permission imagineable. And to repeat: yes, I'm transferrring from a local database (on this box) to another database (on this box) and SSIS is running through BIDS on this box.
At this point I'm beginnning to think that it is broken on Vista, but I can't believe someone else hasn't run into this. However, when I look at the groups - nothing. Any ideas?
I have 3 packages that run consecutively in a main package. Each of these packages read data from a flat file and import it into the Database and then perform some updates and then I use a script component to write the data to a flat file destination and have overwrite flag on the flat file destination to false, however the flat file is not being appended to. All the 3 packages are set to wirte to the same flat file destination each package overwrites the content of the flat file created by the previous packages.
I am wondering why the overwrite = False does not work on the flat file destination. Is there something else that I need to set or is this a defect? Any inputs will be much appreciated.
I have implemented a simple package that has only a Data Flow Task in the Control Flow. The corresponding Data Flow Components are as follows (in the correct order):
1. A Flat File Source adpater which parses a file containing circa 1 million rows. 2. A Script Component that generates IDs for two of my destination tables. 3. A Mulicast Component that distributes all the columns retrieved from the source file as well as the 2 generated keys. 4. Four OLE DB Destination adapters where I insert the data from the different columns together with the generated keys as primary or foreign keys respectively.
My questions are mainly about how the "Flat File Source" and "OLE DB Destination" work behind the scenes.
Questions: A. "Flat File Source" adapter: Does the "Flat File Source" adapter load all the rows from the source file into the memory and then start pushing the rows one by one into the data flow? My concern is actually about the huge sizes of my import files, which might eat up the memory. Or does the "Flat File Source" adapter load a certain number of rows, pushes them into the pipeline and then fetches the next batch based on a certain configuration?
B. "OLE DB Destination": I have set the four OLE DB destinations to "Fast Load" with a commit size of 5,000. Can I ever run into the problem of having for instance 10,000 records inserted in Table1, but only 5,000 inserted in Table2. The error case I am thinking about is as follows: After the second commit on Table1, an erroneous record occurs during the insertion in Table2. Thus, the second commit for Table2 gets rolled back and the whole package fails. In this case, I get an inconsistent state in my database. In other words, how can I synchronize the commit operation in all my destination tables, s.t. they either all commit the same batch or all do not commit it?
hi! I'm just wondering does anyone know how to create an sql command that can search word by word? what i mean is like I have a product with name 'harry potter broom'. I want an sql command where if i type only 'harry broom' this 'harry potter broom' product will show up. Does anyone have any idea? Here's my sql comand: (I'm using asp.net vb script do develop this system) ------------------------------------------------------------------------- query = "select distinct * from product where " & _ "(pname like '%" & keyword & "%' or " & _ "pdesc like '%" & keyword & "%' ) and " & _ "(price >= " & price1 & " and price <= " & price2 & _ ") and status <> 'out of stock' order by price asc" ------------------------------------------------------------------------- Thank you.
We have a table with a column called 'text' Yes, text is a reserved keyword for data type. I can select it 'SELECT text FROM thistable' but when I try to use it in the order clause, 'SELECT text FROM thistable ORDER BY text', I get this error:
'The text, ntext, and image data types cannot be used in an ORDER BY clause'
I know, you're not supposed to used reserved keywords but the person who initially created this didn't know. We would prefer not to change the column name as this would require tons of changes in the code & COM object.
I've got a sproc that we are migrating from SS2K that uses the reserved keyword 'Pivot'. Best way to replace it. I think it is renameable until the select from TempDB (which is mysterious as I can't see a table in tempDB by that name!!) as below...
Hi, I have got a problem. When I try to access my database table Users, I get the following error:
SELECT permission denied on object 'Users', database 'Users', owner 'dbo'.
So I tried to grand this select command in MS Web Data Administration, but it doesnt work. When I try to grand db_datareader role to dbo, I get the following error
[Microsoft][ODBC SQL Server Driver][SQL Server]Cannot use the reserved user or role name 'db_datareader'.
Does someone have an idea where could be a problem?
when i write a query the world lights up with blue, I think I saw someone using [ ] around the word but I no longer remember if this is the way to handle reserve words that have been use as columns names
I'm trying to recreate a MS-SQL database in MySQL. One particular table has a column names "Precision", a reserved word in MySQL. I woudl really prefer to keep this name if possible as it will be referenced in all sorts of places. I've tried single and double quotes, that didn't work.
Is it possible to use reserveds word as column names? How?
Dear Friends,I'm running a SQL 2005 database. Lately (in the last 4 months) my database size has grown exponentially and now totals 2.5 gig (it used to be about 100mb). When I run sp_spaceused i get the following info: Reserved Space 2522MB Data 450MB Indexes 215MB Unused 1856MB <!--[if !supportLineBreakNewLine]--> The unused space is reserved by my two largest tables, one being 542mb (which is a log I create and the size seems fine for the amount of data) reserving 1033mb and the other being 121mb (which is another log and also seems fine) reserving most of the rest.
I have tried running DBCC SHRINKFILE and DBCC CLEANTABLE commands on a backup copy of the database and cannot seem to free the unused space.
I have also tried copying the database in an attempt to reduce the unused reserved space and have tried creating a new database and importing the tables with no luck
Any help would be greatly appreciated, noting that I'm honestly not that technical and would probably need step by step instructions, but if you only have time to point me in the right direction that would also be of great help!
I am attempting to define a Transactional Publication with Updateable Subscriptions.
One of the articles in the definition has a column called "insertDate" The attempt fails with"A .NET Framework error occurred during execution of user-defined routine or aggregate "sp_MSmakeconflicttable_ sqlclr" System.Data.SqlClient.SqlException: Column names in each table must be unique. Column name insertdata in table 'conflict_ <Publication Name>_<TableName>' is specified more than onceDoes sp_MSmakeconflicttable_sqlclr attempt to create a derived table with this additional column.
Must I rename my column.Are there any other names I should watch out for (other than the standard reserved keywords).
I have tried both in sql server 2000 and sql server 2005 the following code:
DECLARE @DOC VARCHAR(100) DECLARE @HDOC INT SET @Doc='<datos><texto><![CDATA[lÃnea átona]]></texto></datos>' EXEC sp_xml_preparedocument @HDOC OUTPUT, @DOC SELECT * FROM OPENXML(@HDOC,'datos',2) WITH (texto nvarchar(50))
I always get an error 6603 in SQL2000 and 6602+8179 in SQL2005, wich means it can't parse the 'Ã' and 'á' characters, though they are in a CDATA. I have tried with <,>,@ characters and it works fine.
I have also tried using 'á' and 'í' without CDATA but I get the same message:
DECLARE @DOC VARCHAR(100) DECLARE @HDOC INT SET @Doc='<datos><texto><línea átona></texto></datos>' EXEC sp_xml_preparedocument @HDOC OUTPUT, @DOC SELECT * FROM OPENXML(@HDOC,'datos',2) WITH (texto nvarchar(50))
Please can anyone help me - I am trying to establish whether there are any reserved symbols in SQL passwords
eg % £ " $ ( / < * etc
The SQL BOL has a list of reserved words but I cannot find a list of reserved symbols.
We have a problem where by for example if the main part of the password is "test" and my user wants to add a punctuation mark into this we get "You are attempting to use an invalid character message"
Specifically
"test$" is accepted "$test" is not accepted None of "te+st" "+test" "test+" are accepted.
Has anyone else come across this and found a list of the logic that produces these results so I can point my users in the right direction?
I have a table which has 6 text columns (tblA).. I no longer require 1 of those text columns and want to reclaim the space that it is currently taking up..
Is the only way to BCP out all the data (except the 1 column i no longer require) drop the column and BCP the data back into the table?
In on of the server tempdb is not releasing the reserved space after completion of data loads,as of now 99% of free space available in data file,we tried to shrink the datafile ,and space has not been released.
Hello all, I have a database that supports two different applications. For arguments sake I'll call them "intelligent app" and "clueless app"
The client that provided me the schema for the clueless app used reserved words as field names. The words used are: value, state, and time
I explained to the client that modifying them could prevent current/future issues.
The client is an "oracle" db (and in my mind should know better but .....) and responded back to me with the following:
BEGIN QUOTE They are not currently reserved and there is no guarantee they will ever be reserved. In fact, the SQL server line eliminates as many words from the reserved list as they add with new releases. There are other words on the possible future reserved keyword list that I do not wish to avoid either unless forced to some day, like depth, size, class, zone, level and others. END QUOTE
Now for the assistance request, where can I find the documented ramifications of using reserved words? I want to have my documentation (and my ducks lined up) when this clients portion of the app fails.
I work for a financial company where we send out lots of correspondence to clients on a daily and monthly basis. This would typically be something like a financial report, account statements, etc. We've decided to use PDF as the format which these documents must be in when our clients receive them.
Our marketing and sales departments designs the templates of these documents using Microsoft Word. They can save these MS Word documents in the Word XML format (either 2003 or 2007). We want it in XML format, because it is text based, and we can therefore string replace the content to update the template with a client€™s information. In the same token RTF would also do, but the file size when converted to RTF is a problem.
What I am looking for is a way to convert this XML into PDF using something like XSL-FO - i.e. we do not want to use the Word Interopt on our Production Server, firstly it is a little slow and secondly the production server is unmanned and we cannot allow a WinWord.EXE process to not close successfully for some or other reason.
I've tried a number of companies' evaluation software to try and achieve this (converting the WordML to PDF via XSL-FO), but so far no luck.
Does anybody know of a stylesheet out there with which I will be able to achieve this? Or an alternative method of converting MS Word files into PDF without using Word to do it?
I have Sql Server 2000 and Word from Office Xp. Since a few weeks, I cannotimport Data from my database towards a Word document. I follow theprocedure, but at the end, it tells me Word cannot find the data source. IfI use Excel, well it works perfectly. What is the gig?thanks