id stringlengths 16 145 | text stringlengths 1 179k | title stringclasses 1
value |
|---|---|---|
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_39_0.txt | Thanks for contributing an answer to Stack Overflow!
* Please be sure to answer the question . Provide details and share your research! | |
Bind_variables_Managing_Transactions/7454351_13_0.txt |
data WORK.&wrk_table. ;
infile &var_fref delimiter = "&delimiter" MISSOVER DSD lrecl=32767 firstobs=2 ;
attrib MEMBER_ID informat=$32. format=$32.;
/*prop_list - Contains list of other column names*/
%do p=1 %to %sysfunc(countw(&prop_list));
attrib %scan(&prop_list,&p) informat=$255.... | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_10_0.txt | All Discussions only Photos only Videos only Links only Polls only
Filtered by: | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_9_0.txt | 6. Companies
7. Labs | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_28_0.txt | 1
* To be pedantic (to help future readers of your question) If you get DPY-3002 you are not using cx_Oracle. You are using python-oracledb. | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_5_0.txt | Sign up or log in to customize your list.
### more stack exchange communities | |
Bind_variables_Managing_Transactions/7454351_61_0.txt | * 2 likes
* 4 in conversation | |
Bind_variables_Managing_Transactions/7454351_47_0.txt | Re: Optimized way to read variable length csv file
Posted 06-04-2021 12:46 AM (3843 views) | In reply to ballardw | |
Bind_variables_Managing_Transactions/Bind_variables_9_1.txt | code to process an IN/OUT collections is similar. Note the
different call to [ ` Cursor.arrayvar() `
](../api_manual/cursor.html#Cursor.arrayvar "Cursor.arrayvar") which creates
space for an array of strings, but uses an array to determine both the maximum
length of the array and its initial value.
in_v... | |
Bind_variables_Managing_Transactions/7454351_34_0.txt | Posted 06-03-2021 09:28 AM (3888 views) | In reply to hhh123
Is this file static? Do you get multiple copies of it over time? (like a
weekly or monthly delivery) | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_49_0.txt | Post Your Answer Discard
By clicking “Post Your Answer”, you agree to our terms of service and
acknowledge you have read our privacy policy . | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_62_0.txt | I have a problem with applying my logic into python code
0 | |
Bind_variables_Managing_Transactions/7454351_1_0.txt | All community This category This board Knowledge base Users Products
cancel
Turn on suggestions | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_35_0.txt | Hi,
I am working with large csv files some of which having the size of 1 to 2 GB.
But I cannot even import them to Stata in such a short time, for example with
one 1.53 GB file I had to wait 2 hours and in the end the process was not
complete and stata stopped responding. I would appreciate your comment on this
an... | |
Bind_variables_Managing_Transactions/7454351_4_0.txt | * Home
* /
* Programming
* /
* Programming
* /
* Optimized way to read variable length csv file
Options | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_35_0.txt | Improve this answer
Follow | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_24_0.txt |
def InConverter(value):
return int(value) # or whatever is needed to convert from numpy.int64 to an integer
def InputTypeHandler(cursor, value, num_elements):
if isinstance(value, numpy.int64):
return cursor.var(int, arraysize=num_elements, inconverter=InConverter)
... | |
Bind_variables_Managing_Transactions/7454351_10_0.txt | Posted 06-03-2021 07:51 AM (3928 views)
Hi, | |
Bind_variables_Managing_Transactions/7454351_39_0.txt | ##- This is not a static file and column name and width can change in each
run. Due to this usecase I have previously used PROC IMPORT to read the
file.-##
0 Likes | |
Bind_variables_Managing_Transactions/7454351_44_0.txt | Used to do some contract data-related work for a large company and they asked
us "why do you charge us a programming surcharge so often". When we explained
that 1) the order of columns in the data they provided, 2) column headings
changed and 3) structure of the content in some of those columns changed
multiple times p... | |
Bind_variables_Managing_Transactions/7454351_36_0.txt | hhh123
Fluorite | Level 6 | |
Bind_variables_Managing_Transactions/7454351_48_0.txt | Actually this is kind of a generic application on which I am working. This is
to be used by multiple consumers each having their own structure of csv file.
So basically I need to handle this varied length and column in code part
itself.
0 Likes | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_27_0.txt | edited Jan 10, 2023 at 3:13
Carlos Luis Rivera | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_43_0.txt | ## Your Answer
Reminder: Answers generated by artificial intelligence tools are not allowed
on Stack Overflow. Learn more | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_35_0.txt | I've made some related and use ` pandasDataFrame.plot `
>>> import pandas as pd
>>> df = pd.DataFrame()
>>> df["activity"] = ['run', 'swim', 'drive']
>>> df["avg"] = [86400,43200,21600]
>>> df
activity avg
0 run 86400
1 swim 43200
2 drive 21600
>>>... | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_32_0.txt | Code:
set obs 58000000
gen id = _n
gen x = rnormal(0, 1)
export delimited test.csv | |
Bind_variables_Managing_Transactions/7454351_26_0.txt |
data _null_;
infile &var_fref obs=1 ;
input;
call symputx('varlist',translate(_infile_,' ',"&delimiter"));
run;
data &wrk_table. (compress=yes) ;
length MEMBDER_ID $32 &varlist $255 ;
infile &var_fref dsd dlm = "&delimiter" truncover firstobs=2 ;
input &var... | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_15_0.txt | Tags: None
* * * | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_16_0.txt | Q&A for work
Connect and share knowledge within a single location that is structured and
easy to search. | |
Bind_variables_Managing_Transactions/Bind_variables_12_0.txt | ## 7.12. Changing Bind Data Types using an Input Type Handler
Input Type Handlers allow applications to change how data is bound to
statements, or even to enable new types to be bound directly.
An input type handler is enabled by setting the attribute [ `
Cursor.inputtypehandler ` ](../api_manual/cursor.html#Cu... | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_70_0.txt | * About
* Press
* Work Here
* Legal
* Privacy Policy
* Terms of Service
* Contact Us
* Cookie Settings
* Cookie Policy
##### Stack Exchange Network | |
Bind_variables_Managing_Transactions/7454351_11_0.txt | I have a comma delimited csv file which has around 240 columns. These columns
are of variable length hence I have used PROC IMPORT(as below) to read the
file.
PROC IMPORT OUT= WORK.&table_name. DATAFILE= holdit DBMS=DLM REPLACE;
DELIMITER="&delimiter.";
GETNAMES=YES;
DATAROW=2;
... | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_47_0.txt | Previous Next
* * * * * * | |
Bind_variables_Managing_Transactions/7454351_22_0.txt | Tom
Super User | |
Bind_variables_Managing_Transactions/7454351_38_0.txt | Re: Optimized way to read variable length csv file
Posted 06-03-2021 09:31 AM (3886 views) | In reply to Tom | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_53_0.txt | Email
Required, but never shown | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_13_0.txt | #1
## Very Large CSV file | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_12_0.txt | Ask questions, find answers and collaborate at work with Stack Overflow for
Teams.
Explore Teams Create a free Team | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_2_0.txt | Loading…
1. ### current community | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_13_0.txt | 3. Teams
4. Ask questions, find answers and collaborate at work with Stack Overflow for Teams. Explore Teams | |
Bind_variables_Managing_Transactions/Bind_variables_0_0.txt | [ python-oracledb ](../index.html)
latest
* [ 1\. Introduction to the Python Driver for Oracle Database ](introduction.html)
* [ 2\. Installing python-oracledb ](installation.html)
* [ 3\. Initializing python-oracledb ](initialization.html)
* [ 4\. Connecting to Oracle Database ](connection_handling.html)
*... | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_69_0.txt | * Teams
* Advertising
* Collectives
* Talent
##### Company | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_31_0.txt | Sorted by: Reset to default
Highest score (default) Trending (recent votes count more) Date modified
(newest first) Date created (oldest first) | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_40_0.txt | Code:
capture program drop save_one_chunk
program define save_one_chunk
local chunk_num = chunk[1]
drop chunk
save chunk_`chunk_num', replace
exit
end
import delimited my_big_csv_file.csv, clear
gen int chunk = ceil(_n/10000000)
runby save_one_chunk, by(chunk) | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_8_0.txt | * Filter
* Time | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_44_0.txt |
global path "E:/Comtradet"
import delimited "E:\Comtrade\type-C_r-ALL_ps-1977_freq-A_px-S2_pub-20041207_fmt-csv_ex-20190512", clear
cd "$path"
some commands
compress
save "$path/1977.dta", replace
Which actually worked but this is my ... | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_6_0.txt | company blog
2. 3. Log in
4. Sign up | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_33_0.txt | This took about 10 minutes to write out a ~1.0 GB file with the 58M
observations and 2 variables. I then imported the dataset using:
Code: | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_26_0.txt | Improve this question
Follow | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_25_0.txt | * python
* pandas
Share | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_53_0.txt | * Featured on Meta
* Testing a new version of Stack Overflow Jobs
* Policy: Generative AI (e.g., ChatGPT) is banned | |
Bind_variables_Managing_Transactions/7454351_9_0.txt | ##
Optimized way to read variable length csv file | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_25_0.txt | This took about 10 minutes to write out a ~1.0 GB file with the 58M
observations and 2 variables. I then imported the dataset using:
Code: | |
Bind_variables_Managing_Transactions/7454351_2_0.txt | Auto-suggest helps you quickly narrow down your search results by suggesting
possible matches as you type.
Showing results for | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_52_0.txt | ### Post as a guest
Name | |
Bind_variables_Managing_Transactions/7454351_55_0.txt | How to Concatenate Values
Learn how use the CAT functions in SAS to join values from multiple variables
into a single value. | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_29_0.txt | ptr808 ptr808
23 5 5 bronze badges | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_22_0.txt | I want to represent the AVG number (which are seconds actually) as
hour(s):minute(s) on y axis.
I think, it cannot be solved because I spent 3 days wit this problem. But to
be more precise, aside of lot of conversations with dateime, timedelta,
timestamp nothing worked. | |
Bind_variables_Managing_Transactions/Bind_variables_8_0.txt | ## 7.8. REF CURSOR Bind Variables
Python-oracledb provides the ability to bind and define PL/SQL REF cursors. As
an example, consider the PL/SQL procedure:
CREATE OR REPLACE PROCEDURE find_employees (
p_query IN VARCHAR2,
p_results OUT SYS_REFCURSOR
) AS
BEGIN
OPEN p... | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_43_0.txt | As I said I cannot even import the data successfully. Please let me know if I
have made mistakes in my script.
To check if the code works I even tried this with only one file in my
directory and still the same thing happened.
Then I tried importing a single csv file using the code below:
Code: | |
Bind_variables_Managing_Transactions/7454351_27_0.txt | hhh123
Fluorite | Level 6 | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_6_0.txt | Collapse
* Posts
* Latest Activity | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_60_0.txt | 8
Are unique constraints on the DB necessary? | |
Bind_variables_Managing_Transactions/7454351_60_0.txt | * 06-03-2021 07:51 AM
* 3929 views | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_77_0.txt | ##### Stack Exchange Network
* Technology
* Culture & recreation
* Life & arts
* Science
* Professional
* Business
* API
* Data | |
Bind_variables_Managing_Transactions/7454351_52_0.txt | Instead of putting only column names into a macro variable, have a dataset
that describes all the necessary variable attributes (name, type, length,
informat, format) and use that in a DATA _NULL_ step which creates the import
code with CALL EXECUTE.
Maxims of Maximally Efficient SAS Programmers
How to convert datas... | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_0_0.txt |
* Login or Register
* * Log in with | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_24_0.txt | Later I have used Timple .
I do not understand how should I create an acceptable datatype for this. | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_19_0.txt | Ask Question
Asked 13 days ago | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_50_0.txt | OK Cancel
X | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_0_0.txt | Skip to main content
Stack Overflow | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_41_0.txt | To use this, you must install the -runby- command, written by Robert Picard
and me, available from SSC. This code will create 6 Stata data sets, called
chunk1.dta through chunk6.dta, each containing 10,000,000 observations (except
the last will be a bit smaller.)
But frankly, for the purpose you describe, I'd just... | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_44_0.txt | Thanks for contributing an answer to Stack Overflow!
* Please be sure to answer the question . Provide details and share your research! | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_63_0.txt | Need to combine two csv files with same number of columns but different
headers using python
#### Hot Network Questions | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_46_0.txt | Email
Required, but never shown | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_33_0.txt |
cursor().inputtypehandler = InputTypeHandler
creates a cursor, sets the attribute and then destroys the cursor! That isn't
what you want. You can set the type handler directly on the connection (as in
` connection.inputtypehandler = InputTypeHandler ` ), or you have to do this: | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_5_0.txt | No announcement yet.
X | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_10_0.txt | 8. Discussions
9. Collectives | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_1_0.txt | * Forums
* FAQ
* Search in titles only | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_39_0.txt | answered Jan 5, 2023 at 6:51
user11717481 user11717481 | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_64_0.txt | 1
Forcing a field uniqueness on the database is it a bad design | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_36_0.txt | To represent time transcurred for a certain number of seconds you can use `
fromtimestamp ` and formatting ` strftime ` but it might not be compatible
with matplotlib, then using ` Timple ` is something related, but graph could
not be properly plotted or maybe it is needed to perform something like
explore data or app... | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_11_0.txt | Clear All
new posts | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_45_0.txt | But avoid …
* Asking for help, clarification, or responding to other answers.
* Making statements based on opinion; back them up with references or personal experience. | |
Bind_variables_Managing_Transactions/7454351_7_0.txt | hhh123
Fluorite | Level 6 | |
Bind_variables_Managing_Transactions/Bind_variables_9_0.txt | ## 7.9. Binding PL/SQL Collections
PL/SQL Collections like Associative Arrays can be bound as IN, OUT, and IN/OUT
variables. When binding IN values, an array can be passed directly as shown in
this example, which sums up the lengths of all of the strings in the provided
array. First the PL/SQL package definition:... | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_29_0.txt | * Shadi Shad
* Join Date: Apr 2021
* Posts: 33
* * * * | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_56_0.txt | * python
* pandas
or ask your own question . | |
Bind_variables_Managing_Transactions/7454351_50_0.txt | * Mark as New
* Bookmark
* Subscribe
* Mute
* * RSS Feed
* * Permalink
* Print
* * Report Inappropriate Content
## | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_9_0.txt | 6. Companies
7. Labs | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_50_0.txt | ### Post as a guest
Name | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_11_0.txt | 10. Communities for your favorite technologies. Explore all Collectives
2. Teams | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_37_0.txt | * Shadi Shad
* Join Date: Apr 2021
* Posts: 33
* * * * | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_41_0.txt | * ` szekond = CustomJSTickFormatter(code = ''' let mins = Math.floor(parseInt(tick)/60); let m = mins%60 < 10 ? "0"+mins%60 : mins%60; let hours = Math.floor(mins/60); let h = hours < 10 ? "0"+hours : hours; return h + ":" +m; ''') ` This what I wanted. Sorry for format I am noob
– ptr808 | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_51_0.txt | * python
* pandas
* cx-oracle
or ask your own question . | |
Bind_variables_Managing_Transactions/7454351_30_0.txt | Thanks @Tom , that worked perfectly. It took around 2 minutes to read the
data and dataset was compressed to 1 GB only.
I just need to verify if reading this compressed dataset in other data steps
increases any processing time or not. | |
Bind_variables_Managing_Transactions/1437166-very-large-csv-file0_18_0.txt | Well, I'm not convinced that breaking the data into subsets and then combining
the descriptive statistics is really the best way to go here. I think the time
it will take you to code the re-combination of the descriptive statistics (and
the risk of doing it incorrectly) will outweigh the time it will take you to
just r... | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_76_0.txt | ##### Company
* About
* Press
* Work Here
* Legal
* Privacy Policy
* Terms of Service
* Contact Us
* Cookie Settings
* Cookie Policy | |
Bind_variables_Managing_Transactions/how-to-convert-string-from-csv-to-hoursminutes4_13_0.txt | 3. Teams
4. Ask questions, find answers and collaborate at work with Stack Overflow for Teams. Explore Teams | |
Bind_variables_Managing_Transactions/dpy-3002-python-value-of-type-int64-is-not-supported-i-need-to-combine-my-co9_44_0.txt | Sign up using Email and Password
Submit |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.