473,756 Members | 3,566 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Access to Oracle Datatypes?

I have an Access2002 table with one field, x, with the value 777.
It is defined as data type=Numeric, field size=long integer. Using
Access's TableExport/ODBC to Oracle9i(creati ng a new table), I get the
Oracle message-1401 "Inserted value too large for column". Defining the
Access table as Number with field size=Decimal solves the problem.
I actually have hundreds of these Number/LongInteger variables in
Access tables. How can I export them to Oracle? Is there an easy way
to change all field sizes to decimal? Or is there a different solution?
thanks, tom g
Nov 12 '05 #1
2 1926
I think your easiest bet would be to create the table(s) with the
correct datatypes from scrath and then copy the data over from the
existing table(s). Here is some code to create a table and a field.
You can use a loop to create several fields. More info in the help
files under "Field", "Type" keywords.

Sub NewField()
Dim dbs As Database, tdf As TableDef, fld As Field
Set dbs = CurrentDb
Set tdf = dbs.CreateTable Def("tbl1")
Set fld = tdf.CreateField ("fld1", dbDouble)
tdf.Fields.Appe nd fld
Set dbs = Nothing
End Sub

Rich

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 12 '05 #2
I left out the dbs.TableDefs.A ppend tdf part

Revision:

Sub NewField()
Dim dbs As Database, tdf As TableDef, fld As Field
Set dbs = CurrentDb
Set tdf = dbs.CreateTable Def("tbl1")
Set fld = tdf.CreateField ("fld1", dbDouble)
tdf.Fields.Appe nd fld
dbs.TableDefs.A ppend tdf
Set dbs = Nothing
End Sub
If you don't append the tdf object, you will never get a table.

Rich

*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 12 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
6197
by: X | last post by:
Howdy: To follow up on a problem with MS Access (2000) and Oracle 9i (9.2.0.x) - History: I am trying to import tables from my Oracle 9i database on RedHat Linux 7.2 to MS Access (2000) on NT. I managed to turn on logging / debugging for ODBC connections and I got a few messages that I am unfamiliar with.
4
19993
by: susmita_ganguly | last post by:
Hi I am trying to upgrade from oracle 8i to oracle 9i on the same server ..I don't know much abt migration . Can anyone help me out. Thanks. Susmita
125
15496
by: Rhino | last post by:
One of my friends, Scott, is a consultant who doesn't currently have newsgroup access so I am asking these questions for him. I'll be telling him how to monitor the answers via Google Newsgroup searches. Scott has heard a lot of hype about DB2 and Oracle and is trying to understand the pros and cons of each product. I'm quite familiar with DB2 but have never used Oracle so I can't make any meaningful comparisons for him. He does not have...
133
9090
by: jonathan | last post by:
hey all, I realize that this question might pop up from time to time, but I haven't seen it a while and things might of changed, so - Right now (July 2004) how does mysql stand up in comparison to oracle? We are seriously considering migrating our multi-processor oracle system to mysql to save on licensing costs, and would need several features that mysql may or may not have:
2
14948
by: Amin Schoeib | last post by:
Hi, Like I see there is no equivalent to the Oracle decode Function In Postgres.Is there maybe somebody who wrote decode as a Function? Schoeib 4Tek Gesellschaft für angewandte Informationstechnologien mbH Schoeib Amin Tel. +49 (0) 69 697688-132
3
23457
by: Jon Ole Hedne | last post by:
My Access 2002-application need to work with tables from both Oracle and Access. To solve this, I want to run some querys on three views in Oracle and import the results into temporary Access-tables. I have tried this: conn.Provider = "Microsoft.Jet.OLEDB.4.0" conn.ConnectionString = "data source=" & datafil & ";Jet OLEDB:Database Password=" conn.Open datafil
2
396
by: thomas goodwin | last post by:
I have an Access2002 table with one field, x, with the value 777. It is defined as data type=Numeric, field size=long integer. Using Access's TableExport/ODBC to Oracle9i(creating a new table), I get the Oracle message-1401 "Inserted value too large for column". Defining the Access table as Number with field size=Decimal solves the problem. I actually have hundreds of these Number/LongInteger variables in Access tables. How can I export...
6
3950
by: robin9876 | last post by:
In an Access 97 (and 2000) database that has linked tables to Oracle which is showing some fields as text when they are numbers in Oracle. In Oracle they are specified to a size e.g. Number(38). This is causing some issues when trying join different tables in a query. How can the correct datatype be defined in Access?
6
3926
by: Jean | last post by:
Hi, I am using an Access 2000 front-end to an Oracle 9 backend. I want to write a query that returns all records that are not older than one year for Column "Status_30" (which is a Date). When I look at the ODBC Datasource in Table DWHADMIN_V_PROBLEM , the Date formatting looks normal to me, like #05/07/2005#. However, when I try using the following in my Access Query :
12
9523
by: wenmang | last post by:
Hi, I am using following Oracle Proc-C compiler: Pro*C/C++: Release 8.1.7.0.0 - Production on Thu Jun 15 15:57:32 2006 (c) Copyright 2000 Oracle Corporation. All rights reserved. I like to use "long long" integer type(64 bit), but it seems that Oracle doesn't like it after execution, and giving me error code -1460, any idea about this? thx
0
9456
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9275
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
1
9843
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9713
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8713
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7248
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6534
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5142
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
3
2666
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.