How to import ole fields to a SQL Server db

Hi, I have an access db. In a table  I have an ole field where I have lots
of Word Docs stored.
I need to pass all the Access database data to a new SQL Server database,
but I have a problem, the word docs... It seems that Access put an header to
the docs stored in its ole field, but I can't find it.
Anyone can help me?
Thank you in advance
Roberto Cerulli


0
Roberto
1/27/2004 8:01:39 AM
access.conversion 3037 articles. 0 followers. Follow

3 Replies
856 Views

Similar Articles

[PageSpeed] 36

Hi Roberto,

Yes, documents stored in an Access OLE field don't consist just of the
contents of the file but also include a wrapper with information about
the parent application of the document and usually a preview image. 

I don't know any way of stripping the file contents out of the wrapper
other than by saving it back to disk (from where you would import it to
the SQL server blob field).

For Word documents the only way I know of doing this is to automate an
Access form containing a ObjectFrame control bound to the OLE field to
fire up Word, activate the embedded document and Save As. (For bitmaps,
Stephen Lebans has written procedures to do this much more elegantly:
www.lebans.com.) It would probably be worth searching at
http://groups.google.com/advanced_group_search in case there is a better
way. 

On Tue, 27 Jan 2004 09:01:39 +0100, "Roberto Cerulli"
<r.cerulli@tiscali.it> wrote:

>Hi, I have an access db. In a table  I have an ole field where I have lots
>of Word Docs stored.
>I need to pass all the Access database data to a new SQL Server database,
>but I have a problem, the word docs... It seems that Access put an header to
>the docs stored in its ole field, but I can't find it.
>Anyone can help me?
>Thank you in advance
>Roberto Cerulli
>

--
John Nurick [Microsoft Access MVP]

Please respond in the newgroup and not by email.
0
John
1/27/2004 8:39:30 PM
Hi John,
Thank you, I used the same routine used by lebans, adapted for word docs:
I get the recordset, then for each record I pass the ole field word doc to
an OLE control Bound. Then I copy the OLE Control Bound content, open a new
word document, paste into it what I have copied and save the document with
the save as using the id of the record as the namen of the doc.
I have a problem, it copy only the first page of the document so I loose the
other pages. Do you know why?
Thank you,
Roberto Cerulli



"John Nurick" <j.mapSoN.nurick@dial.pipex.com> ha scritto nel messaggio
news:tfgd109fddrq4r3bnrav0tfguo7shq7nkv@4ax.com...
> Hi Roberto,
>
> Yes, documents stored in an Access OLE field don't consist just of the
> contents of the file but also include a wrapper with information about
> the parent application of the document and usually a preview image.
>
> I don't know any way of stripping the file contents out of the wrapper
> other than by saving it back to disk (from where you would import it to
> the SQL server blob field).
>
> For Word documents the only way I know of doing this is to automate an
> Access form containing a ObjectFrame control bound to the OLE field to
> fire up Word, activate the embedded document and Save As. (For bitmaps,
> Stephen Lebans has written procedures to do this much more elegantly:
> www.lebans.com.) It would probably be worth searching at
> http://groups.google.com/advanced_group_search in case there is a better
> way.
>
> On Tue, 27 Jan 2004 09:01:39 +0100, "Roberto Cerulli"
> <r.cerulli@tiscali.it> wrote:
>
> >Hi, I have an access db. In a table  I have an ole field where I have
lots
> >of Word Docs stored.
> >I need to pass all the Access database data to a new SQL Server database,
> >but I have a problem, the word docs... It seems that Access put an header
to
> >the docs stored in its ole field, but I can't find it.
> >Anyone can help me?
> >Thank you in advance
> >Roberto Cerulli
> >
>
> --
> John Nurick [Microsoft Access MVP]
>
> Please respond in the newgroup and not by email.


0
Roberto
1/28/2004 3:42:01 PM
Hi Roberto,

Do the Word documents you create this way contain the first page of the
document, or *a picture of the first page*? 

As far as I know you have to actually activate the OLE object - in this
case the embedded Word document - by manipulating (via VBA code) the
Verb and Action properties of the ObjectFrame control. E.g. set Verb to
acOLEVerbOpen and then Action to acOLEActivate. This opens the embedded
document in Word, and saving to disk will then produce a normal Word
file of the embedded document. 


On Wed, 28 Jan 2004 16:42:01 +0100, "Roberto Cerulli"
<r.cerulli@tiscali.it> wrote:

>Hi John,
>Thank you, I used the same routine used by lebans, adapted for word docs:
>I get the recordset, then for each record I pass the ole field word doc to
>an OLE control Bound. Then I copy the OLE Control Bound content, open a new
>word document, paste into it what I have copied and save the document with
>the save as using the id of the record as the namen of the doc.
>I have a problem, it copy only the first page of the document so I loose the
>other pages. Do you know why?
>Thank you,
>Roberto Cerulli
>
>
>
>"John Nurick" <j.mapSoN.nurick@dial.pipex.com> ha scritto nel messaggio
>news:tfgd109fddrq4r3bnrav0tfguo7shq7nkv@4ax.com...
>> Hi Roberto,
>>
>> Yes, documents stored in an Access OLE field don't consist just of the
>> contents of the file but also include a wrapper with information about
>> the parent application of the document and usually a preview image.
>>
>> I don't know any way of stripping the file contents out of the wrapper
>> other than by saving it back to disk (from where you would import it to
>> the SQL server blob field).
>>
>> For Word documents the only way I know of doing this is to automate an
>> Access form containing a ObjectFrame control bound to the OLE field to
>> fire up Word, activate the embedded document and Save As. (For bitmaps,
>> Stephen Lebans has written procedures to do this much more elegantly:
>> www.lebans.com.) It would probably be worth searching at
>> http://groups.google.com/advanced_group_search in case there is a better
>> way.
>>
>> On Tue, 27 Jan 2004 09:01:39 +0100, "Roberto Cerulli"
>> <r.cerulli@tiscali.it> wrote:
>>
>> >Hi, I have an access db. In a table  I have an ole field where I have
>lots
>> >of Word Docs stored.
>> >I need to pass all the Access database data to a new SQL Server database,
>> >but I have a problem, the word docs... It seems that Access put an header
>to
>> >the docs stored in its ole field, but I can't find it.
>> >Anyone can help me?
>> >Thank you in advance
>> >Roberto Cerulli
>> >
>>
>> --
>> John Nurick [Microsoft Access MVP]
>>
>> Please respond in the newgroup and not by email.
>

--
John Nurick [Microsoft Access MVP]

Please respond in the newgroup and not by email.
0
John
1/28/2004 7:16:10 PM
Reply:

Similar Artilces:

Windows server 2000 strange crash
Hi, i have a strange problem in my network, 1 dc 2000 server which is also dhcp server and dns server ,and 1 member server 2003 acting as fileserver. When rebooting the dc, it will work properly. Running dcdiag and netdiag will not show any problems, all tests passing, no errors, no warnings. But after 14 hours (at night when nobodys working), the DC simple stops findind himself...running netdiag gives dc_list and ldap errors, dcdiag wont even run, gives just an error 31 with ldap. After this, i get replication errors, problems with connectivity, leading to server stop responding...

Importing column in comma saparated values.
Hi, This is my first post here..:) I have some values in a column in excel and I want to have them i comma saparated values. The Outout can be in any type of file as lon as I can copy it..I am sure, the experts here can solve this and hel me a great deal...Please help... Thanks in advance. -- Message posted from http://www.ExcelForum.com You could File/Save As then select .CSV ??? --- Message posted from http://www.ExcelForum.com/ If it's just one column (out of many used columns), then I'd just copy and paste into NotePad and save from there. But I'm not quite sure how y...

Execute SQL dts package from Great Plains shortcut
How do create a Great Plains external shortcut to execute a SQL Server dts package? VG You can do this using by using the DTSRun utility in a .bat file and calling that from the shortcut bar. You would need to install SQL Client Tools or the DTSRun utility separately on the client workstation to do so. Google DTSRun or check out these links to help get you started: http://msdn.microsoft.com/library/default.asp?url=/library/en-us/coprompt/cp_dtsrun_95kp.asp http://www.sqldts.com/default.aspx?301 Lookup DTSRun on Yahoo or Google. It will fire a DTS package from a command line. Then cr...

block owa on Back-end server?
Hi, I have setup a Front-End server with Exchange server 2003 and OWA works fun. Now i want to block OWA on the Back-End server (Exchange 2003). That means I just want our users log onto OWA with Front-End server IP address ( Http://front-end ip/exchange)and do not want users log onto the OWA with the Back-End server IP address (Http://Back-end ip/exchange). Could you tell me how to do it? Any idea or info would be greatly appreciated! Thanks. Mike You could do this by limiting what identities the Default Web Site(or whatever web site OWA is under), on the back-end server, will answer for....

Mailboxes in Exchange 2003 Enterprise Server
I have implemented a policy to limit the mailbox size to 30000 K and implemented a 21 day Age Limit. However, 21 days has passed and the 30000 K limit has passed on more than 50% of our mailboxes. How can we enforce this policy to work properly and clean out the mailboxes to bring this down to 30 K. The policy I have created is running and reporting is enabled.It is configured for report only, but I would like this to change to "Move to deleted items folder". However, since nothing seems to happen as of yet...I am hesitant to make the change until I can see a change and tha...

PST IMport problem
I am having problems importing data from a pst backup file. I have successfully imported outlook folders from it recently, however when I attempt to import more now, the files are not coming into my current tree, but a new personal folder is created with nothing in it. The PST file in question has a filesize of over 600Mb ! Any Help will be greatly appreciated! Thanks! For starters, importing and exporting are not recommended for PST files. You've demonstrated one of the reasons. Just open the file. -- Russ Valentine [MVP-Outlook] <neil@energycell.co.uk> wrote in message news...

Changing a custom field length
We have created a custom section and there is a field (in that custom section) whose length has to be changed from 100 to 500 of nvarchar datatype, but the interface does not allow more than 100 for nvarchar. I couldnt modify the format of textbox to textarea as it is disabled nor i can change the datatype to another datatype. can anybody please help me with this?? Affy Unfortunately you'll have to recreate the field, as you can neither increse the length of a text field nor change it's format after it's been created. Then there's a question of what to do with any existing...

A2007 problem on Vista multiuser DB
Hi, I have a A2007 application (ported from A97) running on Vista and Office 2007 Pro. I use two computers in a LAN. The application itself is devided into two DBs (program and data). I have installed the program-DB on both machines and the data-DB on one (server) of them. The same configuration worked well on the former systems (XP pro and A97). Now there come up the following symptoms: Starting the application on the server workes fine. But when starting the application on the client (when on the server its still open (and at least one data bounded form is open) I cannot open any databo...

Learning SQL
Can anyone recommend any good reference books to help me learn SQL. My needs are only as it relates to Access. Any help greatly appreciated. Jason SQL Queries for Mere Mortals by Hernandez and Viescas: http://www.amazon.com/SQL-Queries-Mere-Mortals-Hands/dp/0201433362/ref=pd_bbs_sr_1/103-7818383-4346230?ie=UTF8&s=books&qid=1177897812&sr=8-1 Here's a free tutorial: http://www.sqlcourse.com/intro.html Here's a really basic intro to subqueries: http://allenbrowne.com/subquery-01.html -- Allen Browne - Microsoft MVP. Perth, Western Australia Tips for Access us...

Field lookup query question
Access 2003. I have two tables. Master and IssuePart. Each table has a report number (Master.OA) that ties all this together. I wanted to make the Master table perform a lookup by matching the report number in IssuePart and bringup a listbox. But the query won't cooperate. I can manually enter a report number and get the results I want, but as soon as I try to change the criteria to the Master report number field name, it chokes with syntaxs errors and such. Here's the SQL the Builder produces. SELECT IssueData.[Part Number], IssueData.[Serial Number] FROM IssueData WHERE ((ISS...

Importing marketing list as campaign responses
Hi there guys and thanks in advance for any light you might shed on this matter. I created a .csv file from an excel sheet and I want to import this into CRM as campaign responses. When I try to do so, and after mapping all fields from the file to correspondent fields in CRM, it just doesn't import anything. It seems like it is going to import, but then, just doesn't do nothing. And of course, nothing shows as campaign responses. If I import the .csv file as leads, it works, so I guess the import file is not corrupted or has any bad data. Anyone knows what the problem might be? ...

ftp server or I can saved from Ecxel? #2
I need to fine out how to save a hml workbook onto my website do I need to use ftp server or I can saved from Ecxel? Kosta ...

SQL Server 2005 Express Edition license
Hi We are using SQL Server Express Edition in one ASP .NET web application which will go live and accessed by users situated at different locations. Number of concurrent users and database size of the application is well within the specified limit of SQL Express server. I am concerned about the licensing cost of SQL Server. I understand Express edition is free. Wanted to confirm that use of SQL Server Express edition will be free? Thank you Shailesh Shailesh Yes , it is free and I hope it will "Shailesh" <Shailesh@discussions.microsoft.com> wrote in...

How to read B-LOB data from Oracel DB using Pro*c
Hello, I'm trying to read B-LOB data in Oracle Database using Pro*c. I know how to read it with char mode. What I want to know is read it with binary mode. Are there any good person help me? Let me know if you have a good sample source. Thanks and have a nice day. ...

SMTP on MS EXCHANGE 2000 Server
I have an exchange server set up in our environment but the clients have been set up as pop clients and not as exchange clients. I wont go into the details as to why we have gone for that. The question is that when a client sets its pop server as "abc.mail.com" it receives mails so thats fine but when it writes "abc.mail.com" in SMTP it doesnt send and gives an error as NO TRANSPORT SERVER AVAILABLE. At the moment the clients are using the ISP's SMTP. SMTP connector has been created on mail server and if a client is setup as an EXCHANGE client then there are no issues,...

Exchange 2000 - Additional Server
Hi We have 2 sites, connected via a 256k leased line, separated into 2 subnets. On the site with the Internet gateway, we have an Exchange server 2000, which currently all clients at both sites connect to via Outlook 2000. We have approx 25 users at each site. I would like to put a second exchange server at our remote site, so that when they get attachments etc, they don't have to wait forever etc. We would then have each person's mailbox on the server that they normally use, I can get my site log on scripts to deal with which Exchange server they use. I am thinking maybe we coul...

how to use Field codes in Excel
Hi, I am facing a problem in using custom property values in excel worksheet. Here is my requirement. I want to display the Version No in the footer. how to do the same using custom properties. I have used field codes in Word but could not find the same in excel. Can you pls help ASAP "Radhika" wrote... >I am facing a problem in using custom property values in >excel worksheet. Here is my requirement. I want to >display the Version No in the footer. how to do the same >using custom properties. I have used field codes in Word >but could not find the s...

IIS & Exchange: 2 x SMTP server?
Hi, We have IIS and Exchange running on IIS. The server was accepting incoming SMTP but the message were not stored in Exchange, also some configured domains were not accepted. In IIS and Exchange there is a configuration for SMTP and we suspected that the IIS SMTP got the incoming calls and handled it. We changed the port number of SMTP in Exchange to 8025 and as we thought a telnet session to 25 accepted mails (but not stored in Exchange), when connected to port 8025 mail was stored exchange and other domains were accepted. We tried to stop the smtp server in IIS but at every restart the...

How to install software on a terminal server/use microsoft office through RDP
My boss is asking me to figure this out, so I do not know all the configurations he is using. I can tell you its Windows server 2k3. He wants to be able to RDP to server, and work physically on the server. He also needs to have office 2003 license installed. So the greater question is "how to use ms office 2k3 through RDP on microsoft 2003 server?" -- jgosney ------------------------------------------------------------------------ jgosney's Profile: http://forums.techarena.in/members/159717.htm View this thread: http://forums.techarena.in/windows-server-help/1277...

Imported/merged .ics file into calendar... how to undo/delete?
Hello. I accidentally imported an .ics file into my main calendar and am wondering if there's anyway to remove the entries that came from this ics file from my calendar? Thanks. Add the modified time field to the view then sort by it - all the imported events should be together with the same modified time. -- -- Diane Poremsky [MVP - Outlook] Outlook Tips: http://www.outlook-tips.net/ Outlook & Exchange Solutions Center: http://www.slipstick.com/ Outlook Tips by email: mailto:dailytips-subscribe-request@lists.outlooktips.net EMO - a weekly newsletter about...

SMTP config on an Echange server 2000/2003
Can you setup an exchange server to run smtp only, to be used in a redundancy scenario...the idea being that if the main exchange server goes down, I want to have or put on the network a separate email server that will just collect smtp email until the mail server comes back on line. If the answer is yes...how do you setup the config and are there any articles on the subject. Thanks You don't even need exchange to do that, you can use IIS with SMTP as a smart host. Bascially, the smart host would sit between your exchange Org and the firewall, and act as a passthrough. If exchan...

Migrate data from one CRM server to another
Hello, I need to install a portuguese version of microsoft crm, but actually, we have a english version, and with much data like accounts, contacts, opportunities, etc... inserted. I try to use de redeployment tool to install the portuguese version and import our data, but on the install of microsoft crm portuguese version, I got a error saying that SQL not match the correct version, and don=B4t let setup continue the installation.... maybe a bug.... So, what I need to do is export ALL (or almost all) data from the english version, uninstall crm, reinstall the portuguese version and import ...

Import and Export Calendar
Hi, I bought a new computer set with MS Office xp standard. I want to copy the MS Outlook 2002's calendar to my new computer. Please help Thanks Jimmy Take a look here, it may help: http://www.slipstick.com/config/backup.htm --� Milly Staples [MVP - Outlook] Post all replies to the group to keep the discussion intact. All unsolicited mail sent to my personal account will be deleted without reading. After furious head scratching, Jimmy asked: | Hi, | | I bought a new computer set with MS Office xp standard. I want to | copy the MS Outlook 2002's calendar to my new computer....

Outlook 2000 "Server cannot be found"
I applied all of the current updates for Office 2000 and Windows 2000. Outlook can no longer send or recieve email and presents the "Server cannot be found" message. I have checked the account set up and it is fine. I reestablished the account set up using the sbcglobal tutuorial for account set up in Outlook (just to be certain) and the result was still "Server cannot be found". I also checked that Network and Dial up security is set to Permit All Email fails to find the server via an established DSL connection and it also fails with a dial up connection. I c...

Import/Export problem with Win XP/Outlook 2003 .pst files
Helo all, I have just bought a Vista Home Premium pc (philips freevents LX3000) and am using Office 2003. My problem is this: While using the same office app' on Win XP Home Ed' SP2 I backed up all my Outlook 2003 personal folders for both pop3 and IMAP accounts by using import/export to a .pst file and placed these files on two external hard drives, just for safety reasons in case one of the external hard drives would not work with vista. Both of the external hard drives and their 'names' are recognised by vista and I can see and access almost all of the files on bot...