Merging feature classes in memory gives ERROR 001156?Can variable be set to reference in_memory workspace...
Minimum Viable Product for RTS game?
Linearity Assumption
Is it possible to detect 100% of SQLi with a simple regex?
Do the speed limit reductions due to pollution also apply to electric cars in France?
What is the meaning of "usr"?
Coworker asking me to not bring cakes due to self control issue. What should I do?
What could cause an entire planet of humans to become aphasic?
How can I handle players killing my NPC outside of combat?
Why did Ylvis use "go" instead of "say" in phrases like "Dog goes 'woof'"?
two subject complements in passive form?
If I tried and failed to start my own business, how do I apply for a job without job experience?
Did ancient Germans take pride in leaving the land untouched?
How can I prevent an oracle who can see into the past from knowing everything that has happened?
Is the Maximum Use License for Everybody (MULE) a FOSS license?
Expression for "unconsciously using words (or accents) used by a person you often talk with or listen to"?
Why can't I set the 'prototype' of a function created using 'bind'?
Boss asked me to sign a resignation paper without a date on it along with my new contract
Why is Shelob considered evil?
How bad is a Computer Science course that doesn't teach Design Patterns?
Is Screenshot Time-tracking Common?
Why is it that Bernie Sanders is always called a "socialist"?
Including proofs of known theorems in master's thesis
Can you say "leftside right"?
What if I miss a connection and don't have money to book next flight?
Merging feature classes in memory gives ERROR 001156?
Can variable be set to reference in_memory workspace object in ArcPy?ArcGIS 10.2.1 Table To Table tool in Python script gives ExecuteError: ERROR 001156?Prevent arcpy.Append from crashing if data is too long for fieldHow does GIS detect the error causing field in “ExecuteError: ERROR 001156”How to merge adjacent polygons with no common attributes in GRASS?Merging Two Identical Feature Classes in ArcPy?I can't merge similar layersUnderstanding Merge Error 001156 from ArcGIS Pro?Merging List of shapefiles gives ERROR 000400?
arcpy.AddField_management("in_memory/originalfc","ALPHABET","TEXT",1)
arcpy.Select_analysis("in_memory/originalfc","in_memory/A","attr<=0")
arcpy.CalculateField_management("in_memory/A","ALPHABET",'"A"',"PYTHON")
arcpy.Select_analysis("in_memory/originalfc","in_memory/B","attr>0")
arcpy.CalculateField_management("in_memory/B","ALPHABET",'"B"',"PYTHON")
arcpy.Merge_management(["in_memory/A","in_memory/B"],"in_memory/merged")
When the merge executes I get an error 001156 on OID 1 that says i can't write value 'A' to output field ALPHA.
If I try to append one to the other I get the same error. They were originally the same feature class why won't they go back together?
arcpy arcmap merge in-memory error-001156
bumped to the homepage by Community♦ 9 mins ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
add a comment |
arcpy.AddField_management("in_memory/originalfc","ALPHABET","TEXT",1)
arcpy.Select_analysis("in_memory/originalfc","in_memory/A","attr<=0")
arcpy.CalculateField_management("in_memory/A","ALPHABET",'"A"',"PYTHON")
arcpy.Select_analysis("in_memory/originalfc","in_memory/B","attr>0")
arcpy.CalculateField_management("in_memory/B","ALPHABET",'"B"',"PYTHON")
arcpy.Merge_management(["in_memory/A","in_memory/B"],"in_memory/merged")
When the merge executes I get an error 001156 on OID 1 that says i can't write value 'A' to output field ALPHA.
If I try to append one to the other I get the same error. They were originally the same feature class why won't they go back together?
arcpy arcmap merge in-memory error-001156
bumped to the homepage by Community♦ 9 mins ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
To which line does the error refer? The CalculateField or the Merge?
– Tom
Jan 24 at 17:42
To the merge line
– gomapping
Jan 24 at 17:53
2
If you used an expression in CalculateField you could avoid needing to split and re-merge. Something likearcpy.CalculateField_management("in_memory/originalfc","ALPHA",'"A" if !attr! <= 0 else "B"',"PYTHON")
– mikewatt
Jan 24 at 18:16
1
Does it work when performed in a regular workspace like a file geodatabase?
– PolyGeo♦
Jan 24 at 19:16
add a comment |
arcpy.AddField_management("in_memory/originalfc","ALPHABET","TEXT",1)
arcpy.Select_analysis("in_memory/originalfc","in_memory/A","attr<=0")
arcpy.CalculateField_management("in_memory/A","ALPHABET",'"A"',"PYTHON")
arcpy.Select_analysis("in_memory/originalfc","in_memory/B","attr>0")
arcpy.CalculateField_management("in_memory/B","ALPHABET",'"B"',"PYTHON")
arcpy.Merge_management(["in_memory/A","in_memory/B"],"in_memory/merged")
When the merge executes I get an error 001156 on OID 1 that says i can't write value 'A' to output field ALPHA.
If I try to append one to the other I get the same error. They were originally the same feature class why won't they go back together?
arcpy arcmap merge in-memory error-001156
arcpy.AddField_management("in_memory/originalfc","ALPHABET","TEXT",1)
arcpy.Select_analysis("in_memory/originalfc","in_memory/A","attr<=0")
arcpy.CalculateField_management("in_memory/A","ALPHABET",'"A"',"PYTHON")
arcpy.Select_analysis("in_memory/originalfc","in_memory/B","attr>0")
arcpy.CalculateField_management("in_memory/B","ALPHABET",'"B"',"PYTHON")
arcpy.Merge_management(["in_memory/A","in_memory/B"],"in_memory/merged")
When the merge executes I get an error 001156 on OID 1 that says i can't write value 'A' to output field ALPHA.
If I try to append one to the other I get the same error. They were originally the same feature class why won't they go back together?
arcpy arcmap merge in-memory error-001156
arcpy arcmap merge in-memory error-001156
edited Jan 24 at 20:41
gomapping
asked Jan 24 at 17:29
gomappinggomapping
61031334
61031334
bumped to the homepage by Community♦ 9 mins ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
bumped to the homepage by Community♦ 9 mins ago
This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
To which line does the error refer? The CalculateField or the Merge?
– Tom
Jan 24 at 17:42
To the merge line
– gomapping
Jan 24 at 17:53
2
If you used an expression in CalculateField you could avoid needing to split and re-merge. Something likearcpy.CalculateField_management("in_memory/originalfc","ALPHA",'"A" if !attr! <= 0 else "B"',"PYTHON")
– mikewatt
Jan 24 at 18:16
1
Does it work when performed in a regular workspace like a file geodatabase?
– PolyGeo♦
Jan 24 at 19:16
add a comment |
To which line does the error refer? The CalculateField or the Merge?
– Tom
Jan 24 at 17:42
To the merge line
– gomapping
Jan 24 at 17:53
2
If you used an expression in CalculateField you could avoid needing to split and re-merge. Something likearcpy.CalculateField_management("in_memory/originalfc","ALPHA",'"A" if !attr! <= 0 else "B"',"PYTHON")
– mikewatt
Jan 24 at 18:16
1
Does it work when performed in a regular workspace like a file geodatabase?
– PolyGeo♦
Jan 24 at 19:16
To which line does the error refer? The CalculateField or the Merge?
– Tom
Jan 24 at 17:42
To which line does the error refer? The CalculateField or the Merge?
– Tom
Jan 24 at 17:42
To the merge line
– gomapping
Jan 24 at 17:53
To the merge line
– gomapping
Jan 24 at 17:53
2
2
If you used an expression in CalculateField you could avoid needing to split and re-merge. Something like
arcpy.CalculateField_management("in_memory/originalfc","ALPHA",'"A" if !attr! <= 0 else "B"',"PYTHON")– mikewatt
Jan 24 at 18:16
If you used an expression in CalculateField you could avoid needing to split and re-merge. Something like
arcpy.CalculateField_management("in_memory/originalfc","ALPHA",'"A" if !attr! <= 0 else "B"',"PYTHON")– mikewatt
Jan 24 at 18:16
1
1
Does it work when performed in a regular workspace like a file geodatabase?
– PolyGeo♦
Jan 24 at 19:16
Does it work when performed in a regular workspace like a file geodatabase?
– PolyGeo♦
Jan 24 at 19:16
add a comment |
1 Answer
1
active
oldest
votes
IN_MEMORY is a sort of simplified "geodatabase" but obviously in memory not on a disk. Now the important thing to appreciate is that it is like a geodatabase and thus honours the many specification, but not all, of a geodatabase.
I believe you have been unlucky enough to have chosen a geodatabase RESERVED field name, ALPHA. Suggest you call it something else like "myALPHA".
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "79"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fgis.stackexchange.com%2fquestions%2f309783%2fmerging-feature-classes-in-memory-gives-error-001156%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
IN_MEMORY is a sort of simplified "geodatabase" but obviously in memory not on a disk. Now the important thing to appreciate is that it is like a geodatabase and thus honours the many specification, but not all, of a geodatabase.
I believe you have been unlucky enough to have chosen a geodatabase RESERVED field name, ALPHA. Suggest you call it something else like "myALPHA".
add a comment |
IN_MEMORY is a sort of simplified "geodatabase" but obviously in memory not on a disk. Now the important thing to appreciate is that it is like a geodatabase and thus honours the many specification, but not all, of a geodatabase.
I believe you have been unlucky enough to have chosen a geodatabase RESERVED field name, ALPHA. Suggest you call it something else like "myALPHA".
add a comment |
IN_MEMORY is a sort of simplified "geodatabase" but obviously in memory not on a disk. Now the important thing to appreciate is that it is like a geodatabase and thus honours the many specification, but not all, of a geodatabase.
I believe you have been unlucky enough to have chosen a geodatabase RESERVED field name, ALPHA. Suggest you call it something else like "myALPHA".
IN_MEMORY is a sort of simplified "geodatabase" but obviously in memory not on a disk. Now the important thing to appreciate is that it is like a geodatabase and thus honours the many specification, but not all, of a geodatabase.
I believe you have been unlucky enough to have chosen a geodatabase RESERVED field name, ALPHA. Suggest you call it something else like "myALPHA".
answered Jan 24 at 20:40
HornbyddHornbydd
26.5k32957
26.5k32957
add a comment |
add a comment |
Thanks for contributing an answer to Geographic Information Systems Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fgis.stackexchange.com%2fquestions%2f309783%2fmerging-feature-classes-in-memory-gives-error-001156%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
To which line does the error refer? The CalculateField or the Merge?
– Tom
Jan 24 at 17:42
To the merge line
– gomapping
Jan 24 at 17:53
2
If you used an expression in CalculateField you could avoid needing to split and re-merge. Something like
arcpy.CalculateField_management("in_memory/originalfc","ALPHA",'"A" if !attr! <= 0 else "B"',"PYTHON")– mikewatt
Jan 24 at 18:16
1
Does it work when performed in a regular workspace like a file geodatabase?
– PolyGeo♦
Jan 24 at 19:16